package com.jiuqi.ccp.generator.dao.pojo;

import java.io.Serializable;
import java.math.BigDecimal;
import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;

/** 
 *        @hibernate.class
 *         table="CCP_MAP_COLOR"
 *     
*/
public class CcpMapColor implements Serializable {

    /** identifier field */
    private String cmcGuid;

    /** nullable persistent field */
    private String cmeGuid;

    /** nullable persistent field */
    private String cmcName;

    /** nullable persistent field */
    private String cmcColor;

    /** nullable persistent field */
    private BigDecimal lowLimit;

    /** nullable persistent field */
    private BigDecimal upLimit;

    /** nullable persistent field */
    private String cmcOrder;

    /** nullable persistent field */
    private String reserved1;

    /** nullable persistent field */
    private String reserved2;

    /** nullable persistent field */
    private String reserved3;

    /** full constructor */
    public CcpMapColor(String cmcGuid, String cmeGuid, String cmcName, String cmcColor, BigDecimal lowLimit, BigDecimal upLimit, String cmcOrder, String reserved1, String reserved2, String reserved3) {
        this.cmcGuid = cmcGuid;
        this.cmeGuid = cmeGuid;
        this.cmcName = cmcName;
        this.cmcColor = cmcColor;
        this.lowLimit = lowLimit;
        this.upLimit = upLimit;
        this.cmcOrder = cmcOrder;
        this.reserved1 = reserved1;
        this.reserved2 = reserved2;
        this.reserved3 = reserved3;
    }

    /** default constructor */
    public CcpMapColor() {
    }

    /** minimal constructor */
    public CcpMapColor(String cmcGuid) {
        this.cmcGuid = cmcGuid;
    }

    /** 
     *            @hibernate.id
     *             generator-class="assigned"
     *             type="java.lang.String"
     *             column="CMC_GUID"
     *         
     */
    public String getCmcGuid() {
        return this.cmcGuid;
    }

    public void setCmcGuid(String cmcGuid) {
        this.cmcGuid = cmcGuid;
    }

    /** 
     *            @hibernate.property
     *             column="CME_GUID"
     *             length="32"
     *         
     */
    public String getCmeGuid() {
        return this.cmeGuid;
    }

    public void setCmeGuid(String cmeGuid) {
        this.cmeGuid = cmeGuid;
    }

    /** 
     *            @hibernate.property
     *             column="CMC_NAME"
     *             length="100"
     *         
     */
    public String getCmcName() {
        return this.cmcName;
    }

    public void setCmcName(String cmcName) {
        this.cmcName = cmcName;
    }

    /** 
     *            @hibernate.property
     *             column="CMC_COLOR"
     *             length="6"
     *         
     */
    public String getCmcColor() {
        return this.cmcColor;
    }

    public void setCmcColor(String cmcColor) {
        this.cmcColor = cmcColor;
    }

    /** 
     *            @hibernate.property
     *             column="LOW_LIMIT"
     *             length="38"
     *         
     */
    public BigDecimal getLowLimit() {
        return this.lowLimit;
    }

    public void setLowLimit(BigDecimal lowLimit) {
        this.lowLimit = lowLimit;
    }

    /** 
     *            @hibernate.property
     *             column="UP_LIMIT"
     *             length="38"
     *         
     */
    public BigDecimal getUpLimit() {
        return this.upLimit;
    }

    public void setUpLimit(BigDecimal upLimit) {
        this.upLimit = upLimit;
    }

    /** 
     *            @hibernate.property
     *             column="CMC_ORDER"
     *             length="10"
     *         
     */
    public String getCmcOrder() {
        return this.cmcOrder;
    }

    public void setCmcOrder(String cmcOrder) {
        this.cmcOrder = cmcOrder;
    }

    /** 
     *            @hibernate.property
     *             column="RESERVED1"
     *             length="50"
     *         
     */
    public String getReserved1() {
        return this.reserved1;
    }

    public void setReserved1(String reserved1) {
        this.reserved1 = reserved1;
    }

    /** 
     *            @hibernate.property
     *             column="RESERVED2"
     *             length="100"
     *         
     */
    public String getReserved2() {
        return this.reserved2;
    }

    public void setReserved2(String reserved2) {
        this.reserved2 = reserved2;
    }

    /** 
     *            @hibernate.property
     *             column="RESERVED3"
     *             length="200"
     *         
     */
    public String getReserved3() {
        return this.reserved3;
    }

    public void setReserved3(String reserved3) {
        this.reserved3 = reserved3;
    }

    public String toString() {
        return new ToStringBuilder(this)
            .append("cmcGuid", getCmcGuid())
            .toString();
    }

    public boolean equals(Object other) {
        if ( !(other instanceof CcpMapColor) ) return false;
        CcpMapColor castOther = (CcpMapColor) other;
        return new EqualsBuilder()
            .append(this.getCmcGuid(), castOther.getCmcGuid())
            .isEquals();
    }

    public int hashCode() {
        return new HashCodeBuilder()
            .append(getCmcGuid())
            .toHashCode();
    }

}
